import Router from 'vue-router';
const Home = resolve => require(['@/components/Index.vue'], resolve);
const Flower = resolve => require(['@/components/Flower.vue'], resolve);
const FlowerCorpus = resolve => require(['@/components/FlowerCorpus.vue'], resolve);
const Register = resolve => require(['@/components/Register.vue'], resolve);
const Login = resolve => require(['@/components/Login.vue'], resolve);
const Test = resolve => require(['@/components/Test.vue'], resolve);

export default new Router({
  mode: 'history',
  base: __dirname,
  routes: [
	  {path: '/', name: 'Home', component: Home},
	  {path: '/flower/list', name: 'Flower', component: Flower},
	  {path: '/flower/corpus', name: 'FlowerCorpus', component: FlowerCorpus},
	  {path: '/register', name: 'Register', component: Register},
	  {path: '/login', name: 'Login', component: Login},
	  {path: '/test', name: 'Test', component: Test},
	  {path: '*', redirect: '/'}
  ]
});
